//
//  QuestionDatabase.h
//  GirlsNightOut
//
//  Created by Jeppe Nielsen on 8/23/14.
//  Copyright (c) 2014 Jeppe Nielsen. All rights reserved.
//

#pragma once

#include <string>
#include "Question.hpp"
#include <map>

namespace minijson {
    class value;
}

class QuestionDatabase {
public:
    typedef std::map<int, Question> Questions;
    const Questions& GetQuestions();
    void UpdateFromJSON(std::string json);
    Question* GetQuestion(int index);
    
private:
    void ParseJson(minijson::value& value);
    Questions questions;
};